//
//  NetworkTools+User.swift
//  微博Swift
//
//  Created by  justinchou on 16/2/25.
//  Copyright © 2016年  justinchou. All rights reserved.
//

import Foundation

extension NetworkTools {
    
    /// 加载用户信息
    ///
    /// - parameter uid:          用户代号
    /// - parameter access_token: access_token
    /// - parameter finished:     完成回调
    func loadUserInfo(uid: String, access_token: String, finished:(result: [String: AnyObject]?)->()) {
        
        let urlString = "https://api.weibo.com/2/users/show.json"
        let params = ["uid": uid, "access_token": access_token]
        
        request(.GET, urlString: urlString, parameters: params, finished: finished)
    }
}